package com.jiaomatech.tencent.cos.endpoint;

import org.springframework.boot.actuate.autoconfigure.endpoint.condition.ConditionalOnEnabledEndpoint;
import org.springframework.boot.actuate.endpoint.annotation.Endpoint;
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
import org.springframework.context.annotation.Bean;

/**
 * 增加 Endpoint 监控.
 *
 * @author meng
 */
@ConditionalOnClass(Endpoint.class)
public class CosEndpointAutoConfiguration {

    @Bean
    @ConditionalOnMissingBean
    @ConditionalOnEnabledEndpoint
    public CosEndpoint cosEndPoint() {
        return new CosEndpoint();
    }

}
